//
//  LJM_SONG_Main_CollectionViewCell.m
//  wind
//
//  Created by 李金明 on 16/1/18.
//  Copyright © 2016年 李金明. All rights reserved.
//

#import "LJM_SONG_Main_CollectionViewCell.h"
#define HEIGHT 30//TITLE的高度
@implementation LJM_SONG_Main_CollectionViewCell
- (void)dealloc
{
    [_imageV release];
    [_titleLab release];
    [super dealloc];
}

- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        [self creatView];
    }
    return self;
}
- (void)creatView
{
    self.backgroundColor = [UIColor whiteColor];
    
    self.imageV = [[UIImageView alloc] init];
    self.imageV.backgroundColor = [UIColor whiteColor];
    [self.contentView addSubview:self.imageV];
    [_imageV release];
    
    self.titleLab = [[UILabel alloc] init];
    self.titleLab.font = [UIFont systemFontOfSize:16];
    self.titleLab.backgroundColor = [UIColor whiteColor];
    self.titleLab.textColor = [UIColor grayColor];
    [self.contentView addSubview:self.titleLab];
    [_titleLab release];
}
- (void)layoutSubviews
{
[self.imageV mas_makeConstraints:^(MASConstraintMaker *make) {
    make.top.equalTo(self.mas_top);
    make.left.equalTo(self.mas_left);
    make.right.equalTo(self.mas_right);
    make.bottom.equalTo(self.mas_bottom).offset(-HEIGHT);
}];
[self.titleLab mas_makeConstraints:^(MASConstraintMaker *make) {
    make.bottom.equalTo(self.mas_bottom);
    make.left.equalTo(self.mas_left);
    make.right.equalTo(self.mas_right);
    make.height.mas_equalTo(@HEIGHT);
}];
    
}
/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/

@end
